package com.yami.shop.bean.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 
 * @TableName tz_msg_sub
 */
@TableName(value ="tz_msg_sub")
@Data
@NoArgsConstructor
@AllArgsConstructor
public class MsgSub implements Serializable {
    /**
     * 
     */
    @TableId(type = IdType.AUTO)
    private Long msgSubId;

    /**
     * 
     */
    @NotBlank(message = "留言不可为空")
    private String content;

    /**
     * 
     */
    private String userId;

    /**
     * 
     */
    private Date createTime;

    /**
     * 
     */
    private Date updateTime;

    @NotNull(message = "留言id不可为空")
    private Long msgId;

    private Integer userType;

    private String userName;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public String toString() {
        return "MsgSub{" +
                "msgSubId=" + msgSubId +
                ", content='" + content + '\'' +
                ", userId='" + userId + '\'' +
                ", createTime=" + createTime +
                ", updateTime=" + updateTime +
                ", msgId=" + msgId +
                ", userType=" + userType +
                ", userName='" + userName + '\'' +
                '}';
    }
}